/* 索引签名 */
interface User {
    name: string
    age: number

    // string为键 any为值 数量任意
    [key: string]: any;
}

const u1: User = {
    name: "string",
    age: 19,
    gender: false,
    hobbies: []
}